package com.welkom.everydate.services.interfaces;

import java.util.List;

import com.welkom.everydate.domain.Role;

public interface RoleService {
	/**
	 * 根据条件查询获取符合查询条件的记录的条数
	 * @param role
	 * @return
	 */
	public int getTotalCountByQueryCondition(Role role);
	
	public List<Role> getRolesByPage(Role role,int startIndex,int pageSize);
	
	public void saveChangesToRole(Role role);
	
	public void addRole(Role role);
	
	public void deleteRoleById(long roleId);
	
	public Role getRoleById(long roleId);
	
	public List<Role> getRolesByUserId(long userId);
	
	public List<Role> getAllRoles();
	
	public void removeRolesByUserId(long userId);
	
	public void addRolesToUser(List<Role> roles,long userId);

}
